/**
* @Description: WoShop商城
* @Author: 梧桐
* @Copyright: 武汉一一零七科技有限公司©版权所有
* @Link: www.s1107.com
* @Contact: QQ:2487937004
*/
<template>
	<view style="padding:0 24upx">


		<u-parse :html="content"></u-parse>
		<!-- <view class="" v-html="content"></view> -->
		<!-- <button type="default" @click="bian">改变</button> -->
	</view>
</template>

<script>
	import {
	        mapState,  
	        mapMutations  
	    } from 'vuex'; 
	export default {
		data() {
			return {
				content: '',
				tilte: ''
			}
		},
		onLoad(option) {
			this.title = option.tilte;
			uni.setNavigationBarTitle({
				title: option.tilte
			})
			// this.init();
			uni.request({
				url: 'https://dsx.cdzer.com/api/Article/getArticleById', //仅为示例，并非真实接口地址。
				method: 'POST',
				data:{
					id:option.id
				},
				header: {
					'content-type': 'application/x-www-form-urlencoded',
				},
				success: (res) => {
				console.log(res.data.data.ar_content,"政策列表")
				this.content = res.data.data.ar_content
			}
		});
		},
		methods: {
			...mapMutations(['logout']),
			bian(){
					this.logout()
			},
			init() {
				this.$http.getArticleByTitle({
					tilte: this.tilte
				}).then((res) => {
					if (res.status == 200) {
						this.content = res.data.ar_content;
					}
				})
			},

		}

	}
</script>

<style scoped>
	page {
		background: #ffffff;
		padding-top: 30upx;
	}

	.title {
		font-size: 34upx;
		color: #333;
		line-height: 42upx;
		margin: 20upx 0 40upx;
		text-align: center;
	}
</style>
